You can configure property assertions to compare the expected value of one or more properties with the actual values returned by a rule.
If you have not saved the automated test case, configure the property assertion in the Expected results pane.
Open the PegaUnit test case if it is not already open and then click the Definition tab.
If the test case is open, click the Definition tab.
Complete one of the following actions:
To add a new assertion, Add expected result at the bottom of the page.
Modify an existing assertion in the pane.
From the Assertion type list, select Property.
Specify the page that contains the properties that you want to add or modify.
Specify the page and page class by completing the following steps:
In the Page field, enter the page that contains the properties you want to add or modify.
From the Page class list, select the class to which the page belongs.
Do not specify values for the page or page class. When you add properties for this assertion, as described in the following step, they are populated with page and page class associated with the property.
Complete one of the following tasks:
Add a new property.
Click Add properties.
If you are adding properties for data pages, proceed to step 6.
If you are adding properties for data transforms and activities, complete the following tasks:
From the Thread list, select the thread that contains the page whose properties or pages you want to add.
In the Browse properties of field, select the page whose properties or pages you want to add.
Select the property or page that you want to add. You can search for a property or its value by entering text in the search bar and pressing Enter.
If you select a page, all embedded pages and properties from the page are added. Added properties appear in the right pane.
From the Comparator list, select the comparator that you want to use to compare the property with a specified value.
In the Value field, either enter a value with which to compare the property or open the Expression Builder by clicking the Gear icon to enter an expression that is used to provide the value.
Note: The Gear icon does not appear until after you have saved the rule form.
Optional: To add a comment, click the Add comment icon, enter a comment, and click OK.
If you are adding properties using the property panel, click Done.
Click Save in the rule form.